unit uFilterForm;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls;

type
  TFilterForm = class(TForm)
    Label1: TLabel;
    Edit1: TEdit;
    Button1: TButton;
    Button2: TButton;
    procedure Button2Click(Sender: TObject);
    procedure Button1Click(Sender: TObject);
    procedure Edit1KeyPress(Sender: TObject; var Key: Char);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  FilterForm: TFilterForm;

implementation

{$R *.dfm}

procedure TFilterForm.Button1Click(Sender: TObject);
begin
  ModalResult := mrOk;
end;

procedure TFilterForm.Button2Click(Sender: TObject);
begin
  ModalResult := mrCancel;
end;

procedure TFilterForm.Edit1KeyPress(Sender: TObject; var Key: Char);
begin
  if Key=#13 then
    ModalResult := mrOk;
end;

end.
